package com.springboot.cloud.authorization.service.impl;

import com.springboot.cloud.authorization.provider.SystemProvider;
import com.springboot.cloud.authorization.service.UserService;
import com.springboot.cloud.core.model.SystemUser;
import org.springframework.stereotype.Service;

/**
 * <p>  </p>
 *
 * @author Bertram
 * @since 11/4/2019 4:41 PM
 */

@Service
public class UserServiceImpl implements UserService {

    private SystemProvider systemProvider;

    public UserServiceImpl(SystemProvider systemProvider) {
        this.systemProvider = systemProvider;
    }

    @Override
    public SystemUser getByUniqueId(String uniqueId) {
        return systemProvider.getUserByUniqueId(uniqueId).getData();
    }
}
